<?php declare(strict_types=1);
/**
 * This file is part of Swoft.
 *
 * @link     https://swoft.org
 * @document https://swoft.org/docs
 * @contact  group@swoft.org
 * @license  https://github.com/swoft-cloud/swoft/blob/master/LICENSE
 */

namespace App\Rpc\Service;

use App\Rpc\Lib\PayInterface;
use Exception;
use Swoft\Co;
use Swoft\Rpc\Server\Annotation\Mapping\Service;

/**
 * Class PayService
 *
 * @since 2.0
 *
 * @Service()
 */
class PayService implements PayInterface
{
    /**
     * @return array
     */
    public function pay(): array
    {
        if(true){
            throw new \Exception('未知错误');
        }
        return ['result' => ['ok']];
    }
}
